<#assign base=request.contextPath />
<!DOCTYPE html>
<html>
<head>
<base href="${base}">
<meta charset="utf-8">
<title>周报</title>
<meta name="renderer" content="webkit">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
<link rel="stylesheet" href="${base}/layuiadmin/layui/css/layui.css" media="all">
<link rel="stylesheet" href="${base}/layuiadmin/style/admin.css" media="all">
<link rel="stylesheet" href="${base}/css/my.css" media="all">
<style>
.h1 {
	margin: 20px;
	text-align: center;
}
</style>
</head>
<body>
	<div class="layui-fluid">
		<h1 class="h1">${report.year}年第${report.week}周（${report.weekLen}）周报</h1>
		<div class="layui-row layui-col-space15">
			<div class="layui-col-xs4">
				<div class="layui-card">
					<div class="layui-card-header">
						数据采集 <span class="layui-badge layui-bg-blue layuiadmin-badge">周</span>
					</div>
					<div class="layui-card-body layuiadmin-card-list">
						<p class="layuiadmin-big-font">${report.fetchCnt}</p>
						<p>
							相比上周增加<span class="layuiadmin-span-color">${fetchAdd} 
							<#if (fetchAdd>=0)> 
								<i class="layui-inline layui-icon layui-icon-upload-circle" style="font-size:20px; color: #5FB878;"></i> 
							<#else> 
								<i class="layui-inline layui-icon layui-icon-download-circle" style="font-size:20px; color: #1E9FFF;"></i>
							</#if>
							</span>
						</p>
					</div>
				</div>
			</div>
			<div class="layui-col-xs4">
				<div class="layui-card">
					<div class="layui-card-header">
						敏感信息审核 <span class="layui-badge layui-bg-blue layuiadmin-badge">周</span>
					</div>
					<div class="layui-card-body layuiadmin-card-list">
						<p class="layuiadmin-big-font">${report.checkCnt}</p>
						<p>
							相比上周增加<span class="layuiadmin-span-color">${checkAdd} 
							<#if (checkAdd>=0)> 
								<i class="layui-inline layui-icon layui-icon-upload-circle" style="font-size:20px; color: #5FB878;"></i> 
							<#else> 
								<i class="layui-inline layui-icon layui-icon-download-circle" style="font-size:20px; color: #1E9FFF;"></i>
							</#if>
							</span>
						</p>
					</div>
				</div>
			</div>
			<div class="layui-col-xs4">
				<div class="layui-card">
					<div class="layui-card-header">
						研判及处置<span class="layui-badge layui-bg-blue layuiadmin-badge">周</span>
					</div>
					<div class="layui-card-body layuiadmin-card-list">
						<p class="layuiadmin-big-font">${report.dealwithCnt}</p>
						<p>
							相比上周增加<span class="layuiadmin-span-color">${dwAdd} 
							<#if (dwAdd>=0)> 
								<i class="layui-inline layui-icon layui-icon-upload-circle" style="font-size:20px; color: #5FB878;"></i> 
							<#else> 
								<i class="layui-inline layui-icon layui-icon-download-circle" style="font-size:20px; color: #1E9FFF;"></i>
							</#if>
							</span>
						</p>
					</div>
				</div>
			</div>
		</div>
		<hr>
		
		<#if (topicList?size>0)>
		<blockquote class="layui-elem-quote">本周主题</blockquote>
		<table class="layui-table">
			<thead>
				<tr>
					<th width="20%">日期</th>
					<th width="40%">主题</th>
					<th width="40%">主题译文</th>
				</tr>
			</thead>
			<tbody>
				<#list topicList as tp>
				<tr>
					<td>${tp.statDate?string("yyyy-MM-dd")} </td>
					<td>${tp.topic}</td>
					<td>${tp.remark1}</td>
				</tr>
				</#list>
			</tbody>
		</table><hr>
		</#if>
		
		<div class="layui-row layui-col-space15">
			<div class="layui-col-xs4">
				<div class="layui-card">
					<div class="layui-card-header">
						情感状态分布
					</div>
					<div class="layui-card-body layuiadmin-card-list">
						<div id="chart1" style="width:100%; height:250px;"></div>
					</div>
				</div>
			</div>
			<div class="layui-col-xs4">
				<div class="layui-card">
					<div class="layui-card-header">
						敏感信息状态分布
					</div>
					<div class="layui-card-body layuiadmin-card-list">
						<div id="chart2" style="width:100%; height:250px;"></div>
					</div>
				</div>
			</div>
			<div class="layui-col-xs4">
				<div class="layui-card">
					<div class="layui-card-header">
						预警状态分布
					</div>
					<div class="layui-card-body layuiadmin-card-list">
						<div id="chart3" style="width:100%; height:250px;"></div>
					</div>
				</div>
			</div>
		</div>
		<hr>
		
		<#if (shengHeList?size>0)>
		<blockquote class="layui-elem-quote">预警信息</blockquote>
		<table class="layui-table">
			<thead>
				<tr>
					<th width="30">状态</th>
					<th width="80">日期</th>
					<th width="400">标题</th>
					<th>研判及处置</th>
				</tr>
			</thead>
			<tbody>
				<#list shengHeList as sh>
				<tr>
					<td>
						<#if sh.finaltype==1>
							<i class="layui-icon layui-icon-flag" style="font-weight:bold; font-size:20px; color:#FF5722;"></i> 
						<#elseif sh.finaltype==2>
							<i class="layui-icon layui-icon-flag" style="font-size:20px; color:#FFB800;"></i> 
						</#if>
					</td>
					<td>${sh.shengheDate?string("yyyy-MM-dd")} </td>
					<td>
						<#if sh.dataType==1>${sh.bbsData.title}
						<#else>${sh.mediaData.filename}
						</#if>
					</td>
					<td>${sh.content}</td>
				</tr>
				</#list>
			</tbody>
		</table>
		</#if>
		
	</div>
</body>

<script>
	var __ctxPath = "${base}";
</script>
<script src="${base}/js/yq/echarts.min.js" type="text/javascript"></script>
<script src="${base}/layuiadmin/layui/layui.js"></script>
<script src="${base}/js/commons.js"></script>
<script src="${base}/js/lib/jquery-1.11.3.min.js"></script>

<script>
	layui.config({
		base : '${base}/layuiadmin/' //静态资源所在路径
	}).extend({
		index : 'lib/index'
	}).use([ 'index'], function() {
		
		var data1 = JSON.parse('${report.qingganData}');
		show_chart('chart1', data1, '情感状态分布');
		
		var data2 = JSON.parse('${report.minganData}');
		show_chart('chart2', data2, '敏感信息状态分布');
		
		var data3 = JSON.parse('${report.yujingData}');
		show_chart('chart3', data3, '预警状态分布');

	});
	
function show_chart(id, data, name) {
	var dx = [], dy = [];
	for(x in data) {
		dx.push(x);
		dy.push({name: x, value: data[x]});
	}
	
	var myChart = echarts.init(document.getElementById(id));
	var option = {
		tooltip : {
			trigger: 'item',
	        formatter: '{a} <br/>{b} : {c} ({d}%)'
		},
		legend: {
	        left: 'left',
	        data: dx
	    },
		series : [{
			name : name,
			type: 'pie',
            radius: '50%',
            center: ['50%', '60%'],
			data: dy
		} ]
	};
	myChart.setOption(option);
}
</script>

</html>

